#clear all binds...?
#unbind-key -a #oh, it really means all, not just reset to default.

##############################################################################80
## set -g default-shell /bedrock/strata/artix/usr/bin/fish
#set -g default-shell /bedrock/strata/void/usr/bin/fish
# rrr. i thought this was working, but no.  where did i set this and how?
#
# .. maybe issued as a command manually in tmux n everything's fine then?


#set -g default-shell 'strat void fish'
#nope

#perhaps just...
#strat void
# nope

# but that's weird, now it has defaulted back to tinytoot instead of artix, after that change.  curious.
# trying this again then...
#set -g default-shell /bedrock/strata/void/usr/bin/fish
# weird.  applying that, and a fresh tmux makes artix default again.  ... i've not done a symlink jank have i?  oh noes.  lol.

#anyways lets keep trying things
#set -g default-shell 'strat void /bedrock/strata/void/usr/bin/fish'

# switching this off again... #20280901  ... lol, was all likely a silly mistake, unecessary, anyway.
#set -g default-shell /bedrock/strata/void/usr/bin/fish

# switching this on again... #20280901  ... lol, or is this a mistake too... lol
#set -g default-shell /bedrock/strata/artix/usr/bin/fish
# or


####20240915# pause that, stripping all silly pinnings to see what's really what.  in fish, here, and bedrock.conf, all of it... commenting out this line:
#set -g default-shell /home/digit/bin/artixfish
#eyyyy, that works to get artix loading.
# :)  works.   but is still utter jank.
# gotta remember a more sane way i did this before.

# and.. wat was the way to do the thing... to ensure a universal thing gets applied... set -gU or something?  ... or an e or x or something too?   ... look that up now.  :3


#noooo, it didnt like that this time, prevented new tabs... wat...
#oh, did i break the artixfish script... 
#yeah
#so
#do it properly...
#set -g default-shell /bedrock/strata/artix/usr/bin/fish
#no!  it still didnt like that.
#set -g default-shell fish
#set -g default-shell bash
# nope nope nope... wat i do wrong?  heh.  how i get my tmux to launch a specific strata's fish again?  ... ohhhh... just start it from the desired stratum?
#

# okay, lets try one more way...

#set -g default-shell 'strat artix fish'
#nope

# okay, lets try one more way...

set -g default-shell /bedrock/strata/artix/usr/bin/fish
#it works now.  wat.   idk what interfered with that working before, but, from here we go.  :)

##exec strat void

#idk...

#yea that's reall not the way to do that.  XD

###  HHHHHHOOOOWWWWWWW DID I DO IT BEFORE?  :3
###  ... saw how once, copied it, then forgot.

##############################################################################80

# if
#set -g window-active-style 'fg=colour250,bg=black'
# will work, will
#set -g pane-active-style 'fg=red,bg=white'
# work?
# ... seems not.
# so maybe...
#select-pane -t:.1 -P 'fg=blue,bg=red'
# will help show the way, and i'll be able to
## select-pane -t:active -P 'fg=blue,bg=red'
# or something?  ... try the manual's -t:.1 see what it does first...
### well that's weird, it has coloured one pane in this active window, but no others... not even new
# ok, lets try select-pane -t:active -P 'fg=blue,bg=red'
# select-pane -t:active -P 'fg=blue,bg=green'
# nah, didnt seem work...  maybe......
#select-pane -t: -P 'fg=white,bg=green'
# nah.  idk if still doing the prior.  would be cool if i could do fish style insertion
#select-pane -t:($current) -P 'fg=white,bg=green'
#but noh "select-pane -t: -P 'fg=white,bg=green'" seems apply to the pane while tmux is refreshed.
#
#    need to find out how to get it to
#                ...
#   apply to current-pane, when switching pane,
#   and leave last-pane restored to default.
#
# ok, trial and erroring
# manually applied 
#select-pane -t: -P 'fg=yellow,bg=blue'
# suggests
# the -t:
# means select the current pane.  -t:0 first pane.
# but that current one, again, this is an applied once thing, not following around like 
#  * pane-border-style
#  and
#  * pane-border-active-style
# follow the active pane around.
#
# so
#  seeking to make/find what's effectively:
#
#   pane-style
#   and
#   pane-active-style
#
# maybe pane-color things?
#
# so like
# set -g pane-border-style 'fg=cyan bg=black bold'
# set -g pane-active-border-style 'fg=brightyellow bg=green'
#  
# logically, shouldnt
#set -g pane-style 'fg=cyan bg=black bold'
#set -g pane-active-style 'fg=brightyellow bg=green'
# work?
# or will it be more like
#set -g pane-active-style 'fg=color9 bg=color1'
#?
#set -g active-style 'fg=color9 bg=color5'
#set -g pane-color 'fg=cyan bg=black bold'
#set -g pane-active-color 'fg=brightyellow bg=green'
# or, ah-ha, this at least exist in the man page
#set -g status-style 'fg=black bg=green'
#set -g status-style 'fg=black bg=cyan'
#set -g status-style 'fg=color15 bg=color4'   ###### doing this at the bottom now, neater.
# but isnt a:
#set -g status-active-style 'fg=brightyellow bg=green'
# ..
# searching status-style in man page, does show
# a segment using %if, %elif, %else, %endif...
# so
#  how do i get it to %if upon active-pane
# wait, before that lemme test set -g status-style 'fg=cyan bg=black bold', and, also, the prior style, with -t:active-pane... no wait that wouldnt work would it?  maybe i just needed set -g it already?
# well, nope
# still seeing the statically applied select-pane -t: -P 'fg=yellow,bg=blue' from earlier.  no apparent effect from that status-style... OH  that's the status bar.  doofus.  n_n  brain clearly getting too close, not seeing forest for trees.   ...  lol.
#  better make these notes make sense before taking a break so i can pick up where last left it at easier.
#
#
#  so...
#  select-pane -t: -P 'fg=yellow,bg=blue'
#  is a way to apply to current pane.
# lemme just try
#set -g select-pane -t: -P 'fg=cyan,bg=blue'
# okay, that errored.  demands two arguments.
#set -g select-pane -t: -P 'fg=cyan,bg=blue'
# why?  ... because select-pane's like redundant?
#
# oh hey,
#        pane-colours[] colour
#  can change the default colour pallete...
# lets try...
#set -g pane-colours "-t: 'fg=magenta,bg=yellow'"
# nope, null apparent effect.  but no error at least, with my janky try of wrapping in double quotes.  :3
#lets try:
#set -g pane-colours 'fg=magenta bg=green'
# nope, complains about the colours.   must be some syntactical magic missing yet.
#
# just seen i have
#setw -g window-status-current-style 'fg=colour3 bg=colour0 bold'
# so wouldnt it be nice if there were a
#setw -g pane-current-style 'fg=white bg=blue'
#it didnt error...
### o yes it does.
# it also apparently does not do anything
# lemme just try
#
#set -g something-made-up 'fg=magenta,bg=green'
# yeah, the things that dont exist dont error.
#setw -g something-made-up 'fg=magenta,bg=green'

###

##############################################
# tmux-resurrect and tmux-continuum         ##
set -g @plugin 'tmux-plugins/tmux-resurrect'##
set -g @plugin 'tmux-plugins/tmux-continuum'##
#                                           ##
set -g @continuum-restore 'on'              ##
##############################################

# oi... get those working again^   (after i do this one little thing...)

################################################################################
# oh this is cool.  titles on pane.s  and i can re-name them.  :)             ##
######### (remind how)  tmux select-pane -T                                   ##
#... wont that be nice with tmux-continuum                                    ##
set -g pane-border-status top                                                 ##
################################################################################


## STYLE STUFF ########################################################
#                                                                    ##
# borders                                                            ##
set -g pane-border-style 'fg=cyan bg=black bold'                     ##
set -g pane-active-border-style 'fg=brightyellow bg=green'           ##

# copy mode
#setw -g mode-style 'fg=colour1 bg=colour18 bold'

# statusbar
#set -g status-position bottom
#set -g status-justify left
#set -g status-style 'fg=colour1'
#set -g status-left ''
#set -g status-right '%Y-%m-%d %H:%M '
set -g status-right '%Y%m%d %H:%M:%S '
set -g status-right-style 'fg=color15'
set -g status-left-style 'fg=color15'
set -g status-right-length 19
set -g status-left-length 22

setw -g window-status-current-style 'fg=color15 bg=color5'
setw -g window-status-current-style 'fg=colour3 bg=colour0 bold'

#setw -g window-status-style 'fg=colour1 dim'
#setw -g window-status-format ' #I #[fg=colour7]#W #[fg=colour1]#F '
#setw -g window-status-bell-style 'fg=colour2 bg=colour1 bold'
setw -g window-status-last-style 'fg=colour2 bold'

#setw -g window-status-style 'fg=colour7 bg=color12'
#setw -g window-status-style 'fg=colour7 bg=color4'
setw -g window-status-style 'fg=colour15 bg=color4'

set -g status-style 'fg=color15 bg=color4'
#set -g status-style 'fg=color15 bg=color12'

#set -g status-left ''
#set -g status-left-length 10

#set -g status-right-style 'fg=black bg=yellow'
#set -g status-right '%Y-%m-%d %H:%M '
#set -g status-right-length 50


#setw -g window-status-current-format ' #I #W #F '



# messages
#set -g message-style 'fg=colour2 bg=colour0 bold'

# status bar clock

# clock-mode clock 
set-option -g clock-mode-colour white

# cursor
set-option -g cursor-style 'blinking-block'

                                                                     ##
#######################################################################

## MESSAGE STUFF #################
# keep messages (1000=1s) ########
set-option -g display-time 8000 ##
##################################

##############################################################################80

## PANE MANAGEMENT THINGS  #####################################################
#                                                                             ##
#join-pane [-dhv] [-l size | -p percentage] [-s src-pane] [-t dst-pane]       ##
#    (alias: joinp)                                                           ##
#    Like split-window, but instead of splitting dst-pane and creating        ##
#    a new pane, split it and move src-pane into the space.  This can         ##
#    be used to reverse break-pane.                                           ##
#To simplify this, I have these binds in my .tmux.conf for that:              ##
#                                                                             ##
# pane movement                                                               ##
bind-key j command-prompt -p "join pane from:"  "join-pane -s '%%'"           ##
bind-key s command-prompt -p "send pane to:"  "join-pane -t '%%'"             ##
#                                                                             ##
## 									      ##
# easy switch panes (no prefix bind)                                          ##
bind -n M-Left select-pane -L                                                 ##
bind -n M-Right select-pane -R                                                ##
bind -n M-Up select-pane -U                                                   ##
bind -n M-Down select-pane -D                                                 ##
#                                                                             ##
#default split                                                                ##
#bind-key \" split-window -h                                                  ##
#bind-key % split-window -v                                                   ##
# easy split                                                                  ##
bind-key h split-window -h                                                    ##
bind-key v split-window -v                                                    ##
#or                                                                           ##
bind-key | split-window -h                                                    ##
bind-key - split-window -v                                                    ##
#                                                                             ##
# easy shift arrow to switch window (wont want this if wanting that in emacs in tmux.  will override.)    ##
# do want to change that bind tho, since S-Left/Right is what yakuake uses too##
bind-key -n S-Left previous-window                                            ##
bind-key -n S-Right next-window                                               ##
#                                                                             ##
# synchronize panes                                                           ##
#     wow.  same commands typed into all panes n view.                        ##
#     works ssh'd in to other systems.  wow.                                  ##
bind-key y set-window-option synchronize-panes\; display-message "synchronize mode toggled."  ##
##
# easy pane navigation                                                        ##
bind -n M-w select-pane -U                                                    ##
bind -n M-a select-pane -L                                                    ##
bind -n M-s select-pane -D                                                    ##
bind -n M-d select-pane -R                                                    ##

#easy pane rename                                                             ##
# "C-b ," renames winow, "    " renames session, "C-b M-," renames pane       ##
bind-key M-, command-prompt -p "Enter new pane name: " "select-pane -T '%%'"  ##
#easier pane rename                                                           ##
#bind -n M-r command-prompt -p "Enter new pane name: " "select-pane -T '%%'"  ##
##                                                                            ##
##############################################################################80
#

## SCROLL STUFF ####################################################
# more scrollback (i made this up... see if there's a real one)   ##
#set-option -g scrollback-lines 9000 	    	      	   	  ##
#there is!  and i wasnt far off.				  ##
set-option -g history-limit 9000				  ##
####################################################################

##############################################################################80
## MOUSE STUFF #################################################################
#mouse mode                                                                   ##
set -g mouse on                                                               ##
#bind -n M-m set -g mouse off \; display-message "mouse toggled off"          ##
bind-key m set -g mouse \; display-message "mouse toggled"                    ##
#bind -n C-m set -g mouse on  \; display-message "mouse toggled on"           ##
# aw^, does this instead of "enter".                                          ##
#bind -n C-n set -g mouse on  \; display-message "mouse toggled on"           ##
#bind -u Enter # nope                                                         ##
#unbind Enter #doesnt work.  so i guess it's C-j for enter until this gets mended.##
#unbind C-m #doesnt work.  so i guess it's C-j for enter until this gets mended.##
#unbind-key -a Enter #doesnt work.  so i guess it's C-j for enter until this gets mended.##
#unbind-key -a C-m #doesnt work.  so i guess it's C-j for enter until this gets mended.##
#################################################################################

## CLIPBOARD STUFF ##################################################################
# clipboard mode                                                                   ##
#set -s set-clipboard on                                                           ##
#toggle clipboard modes.                                                           ##
#bind-key c set -g set-clipboard \; display-message "clip toggled"                 ##
###bind-key c set -g set-clipboard on \; display-message "clip toggled ON"         ##
#####bind-key C set -g set-clipboard on \; display-message "clip toggled ON"       ##
#^ stuff like that, if ye like.   ... kinda.                                       ##
#####################################################################################

## CONFIG RELOAD STUFF #####################################################################
# easy config reload                                                                      ##
bind-key r source-file ~/.tmux.conf \; display-message "tmux.conf reloaded"               ##
#bind-key r source-file ~/.config/tmux/tmux.conf \; display-message "tmux.conf reloaded"  ##
############################################################################################

######## MISC...   /     UNSORTED... 
############################################################################################################################################################

# full colour
set-option -sa terminal-overrides ",xterm*:Tc"

##############################################################################

#######################################################################
### here followss a [now being edited] paste of the example default in ... ###
### +48.0°C20231014 16:27:13 mozart gentoostudio /home/digit %
### cat /bedrock/strata/jentoo/usr/share/doc/tmux-3.3a-r1/example_tmux.conf >> .tmux.conf
###
### and then i see weird things launch when i refresh my config, and i think, this is not default...
###
###  oh no, oh it's all yuck.  this is not normal stuff.  ... 
#
#####################
#
# Example .tmux.conf
#
# By Nicholas Marriott. Public domain.
#

# Some tweaks to the status line
#set -g status-right "%H:%M"
#set -g window-status-current-style "underscore"

# If running inside tmux ($TMUX is set), then change the status line to red
#%if #{TMUX}
#set -g status-bg red
#%endif

# Enable RGB colour if running in xterm(1)
#set-option -sa terminal-overrides ",xterm*:Tc"

# Change the default $TERM to tmux-256color
#set -g default-terminal "tmux-256color"

# No bells at all
#set -g bell-action none

# Keep windows around after they exit
#set -g remain-on-exit on

# Change the prefix key to C-a
#set -g prefix C-a
#unbind C-b
#bind C-a send-prefix

# Turn the mouse on, but without copy mode dragging
#set -g mouse on
#unbind -n MouseDrag1Pane
#unbind -Tcopy-mode MouseDrag1Pane

# Some extra key bindings to select higher numbered windows
#bind F1 selectw -t:10
#bind F2 selectw -t:11
#bind F3 selectw -t:12
#bind F4 selectw -t:13
#bind F5 selectw -t:14
#bind F6 selectw -t:15
#bind F7 selectw -t:16
#bind F8 selectw -t:17
#bind F9 selectw -t:18
#bind F10 selectw -t:19
#bind F11 selectw -t:20
#bind F12 selectw -t:21

# A key to toggle between smallest and largest sizes if a window is visible in
# multiple places
#bind F set -w window-size

# Keys to toggle monitoring activity in a window and the synchronize-panes option
#bind m set monitor-activity
#bind y set synchronize-panes\; display 'synchronize-panes #{?synchronize-panes,on,off}'

# Create a single default session - because a session is created here, tmux
# should be started with "tmux attach" rather than "tmux new"
#new -d -s0 -nirssi 'exec irssi'
#set -t0:0 monitor-activity on
#set -t0:0 aggressive-resize on
#neww -d -ntodo 'exec emacs ~/TODO'
#setw -t0:1 aggressive-resize on
#neww -d -nmutt 'exec mutt'
#setw -t0:2 aggressive-resize on
#neww -d
#neww -d
#neww -d

################### new theming ##########################
#
# ... will tidy later.       pasting above.

# DESIGN TWEAKS

# don't do anything when a 'bell' rings
#set -g visual-activity off
#set -g visual-bell off
#set -g visual-silence off
#setw -g monitor-activity off
#set -g bell-action none

# clock mode
#setw -g clock-mode-colour yellow

# copy mode
#setw -g mode-style 'fg=black bg=red bold'

# panes
#set -g pane-border-style 'fg=red'
#set -g pane-active-border-style 'fg=yellow'

# statusbar
#set -g status-position bottom
#set -g status-justify left
#set -g status-style 'fg=red'
#set -g status-style 'fg=color15 bg=color4'

#set -g status-left ''
#set -g status-left-length 10

#set -g status-right-style 'fg=black bg=yellow'
#set -g status-right '%Y-%m-%d %H:%M '
#set -g status-right-length 50

#setw -g window-status-current-style 'fg=color15 bg=color5'
#setw -g window-status-current-format ' #I #W #F '

#setw -g window-status-style 'fg=colour7 bg=color12'
#setw -g window-status-format ' #I #[fg=white]#W #[fg=yellow]#F '

#setw -g window-status-bell-style 'fg=yellow bg=red bold'

# messages
#set -g message-style 'fg=yellow bg=red bold'


#
#
########################################################################